Don't segfault when setting opacity on an offscreen window
authorMatthias Clasen <mclasen@redhat.com>
Wed, 10 Jul 2013 00:05:46 +0000 (20:05 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Wed, 10 Jul 2013 00:05:46 +0000 (20:05 -0400)
This was causing the treeview tests to fail.

gdk/gdkoffscreenwindow.c

index 86b77a190cbf0250c4d1392bfc8a4436be002bcc..fda8907783ea862e3e35fa84366077e2b2811366 100644 (file)
@@ -690,6 +690,11 @@ gdk_offscreen_window_get_scale_factor (GdkWindow *window)
   return gdk_window_get_scale_factor (window->parent);
 }
 
+static void
+gdk_offscreen_window_set_opacity (GdkWindow *window, gdouble opacity)
+{
+}
+
 static void
 gdk_offscreen_window_class_init (GdkOffscreenWindowClass *klass)
 {
@@ -764,7 +769,7 @@ gdk_offscreen_window_class_init (GdkOffscreenWindowClass *klass)
   impl_class->begin_move_drag = NULL;
   impl_class->enable_synchronized_configure = gdk_offscreen_window_do_nothing;
   impl_class->configure_finished = NULL;
-  impl_class->set_opacity = NULL;
+  impl_class->set_opacity = gdk_offscreen_window_set_opacity;
   impl_class->set_composited = NULL;
   impl_class->destroy_notify = NULL;
   impl_class->register_dnd = gdk_offscreen_window_do_nothing;